java.lang.Object
ddejonge.bandana.calculators.ScoreCalculator
ddejonge.bandana.calculators.RankCalculator
- All Implemented Interfaces:
java.io.Serializable
public class RankCalculator extends ScoreCalculator
- See Also:
- Serialized Form
-
Field Summary
-
Constructor Summary
Constructors Constructor Description RankCalculator()
-
Method Summary
Modifier and Type Method Description void
calculateGameScore(GameResult newResult, java.lang.String teamName)
Calculates the score of the given team for the given game.java.lang.String
getScoreString(java.lang.String teamName)
Returns the string to display in the table of the TournamentObserver.java.lang.String
getScoreSystemName()
Returns the name of this score system.double
getTournamentScore(java.lang.String teamName)
Returns the overall score of the given team for the entire tournament.Methods inherited from class ddejonge.bandana.calculators.ScoreCalculator
addResult, getScoreList, getTeamMembers
-
Constructor Details
-
RankCalculator
public RankCalculator()
-
-
Method Details
-
calculateGameScore
Description copied from class:ScoreCalculator
Calculates the score of the given team for the given game.- Specified by:
calculateGameScore
in classScoreCalculator
-
getTournamentScore
public double getTournamentScore(java.lang.String teamName)Description copied from class:ScoreCalculator
Returns the overall score of the given team for the entire tournament.
The TournamentObserver will sort the teams based on to the values returned by this method.- Specified by:
getTournamentScore
in classScoreCalculator
- Returns:
-
getScoreSystemName
public java.lang.String getScoreSystemName()Description copied from class:ScoreCalculator
Returns the name of this score system.- Specified by:
getScoreSystemName
in classScoreCalculator
- Returns:
-
getScoreString
public java.lang.String getScoreString(java.lang.String teamName)Description copied from class:ScoreCalculator
Returns the string to display in the table of the TournamentObserver.- Specified by:
getScoreString
in classScoreCalculator
- Returns:
-